import {createApp} from 'vue'
import {createPinia} from "pinia"; // pinia
import piniaPluginPersistedstate from "pinia-plugin-persistedstate"; // pinia持久化
import App from './App.vue'
import router from './router';
import './router/defend'; // 路由守卫

// pinia 持久化注册
const store = createPinia();
store.use(piniaPluginPersistedstate); // 默认即为JSON序列化

const app = createApp(App)
app.use(router)
app.use(store)
app.mount('#app')